﻿.table-fixed-header .table thead tr th.dropdown-table-fixed-header-visible {
    z-index: 11;
}

.dropdown-menu-position-strategy {
    width: max-content;
    top: 0;
    left: 0;
}

.dropdown-menu-position-strategy-absolute {
    position: absolute;
}

.dropdown-menu-position-strategy-fixed {
    position: fixed;
}

.dropdown-toggle.dropdown-toggle-hidden::after {
    content: none !important;
}

.dropdown-toggle.dropdown-toggle-hidden::before {
    content: none !important;
}

.dropdown-menu.show {
    animation-duration: 0.3s;
    animation-fill-mode: both;
    animation-name: fadeIn;
}

.dropdown-menu a:not([href]).dropdown-item:not(.disabled) {
    cursor: pointer;
}

.dropdown-menu.dropdown-menu-scrollable {
    max-height: var(--dropdown-list-menu-max-height, 200px);
    overflow-y: scroll;
    border-radius: 4px;
    background-clip: border-box;
    background-color: #fff;
    box-shadow: 0 8px 10px 1px rgba(0, 0, 0, 0.14), 0 3px 14px 2px rgba(0, 0, 0, 0.12), 0 5px 5px -3px rgba(0, 0, 0, 0.20);
}

.b-dropdown-list .dropdown-menu:before {
    box-shadow: none;
}

.b-is-autocomplete .dropdown-menu {
    width: 100%;
    max-height: var(--autocomplete-menu-max-height, 200px);
    overflow-y: scroll;
    border-radius: 4px;
    background-clip: border-box;
    background-color: #fff;
    box-shadow: 0 8px 10px 1px rgba(0, 0, 0, 0.14), 0 3px 14px 2px rgba(0, 0, 0, 0.12), 0 5px 5px -3px rgba(0, 0, 0, 0.20);

    .dropdown-item.focus {
        background-color: rgba(0,0,0,.12);
        outline: 0;
        color: rgba(0,0,0,.87) !important;
        text-decoration: none;
    }
}

.b-is-autocomplete.b-is-autocomplete-multipleselection {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    padding-top: 0.25rem;
    max-width: 100%;
    width: 100%;
    cursor: text;

    > input.form-control {
        margin-left: .5rem;
        display: inline-block;
        background-color: transparent;
        max-width: inherit;
        width: auto;
        flex-grow: 1;
    }

    > .badge {
        margin-top: 0.25rem;
        margin-bottom: 0.25rem;
        line-height: 1.5;
        flex-grow: initial;
    }
}


.b-is-autocomplete .dropdown-menu:before {
    box-shadow: none;
}

.dropdown {
    position: relative;

    .btn.dropdown-toggle:not(.btn-outline) {
        box-shadow: none;
    }

    &.dropdown-disabled.b-is-autocomplete {
        background-color: var(--b-theme-light, #e9ecef);
    }

    > .dropdown-menu:not([x-placement]) {
        > .dropdown:not(.dropup, .dropleft, .dropright) {
            position: relative;

            > .dropdown-toggle {
                width: 100%;

                &::after {
                    content: "arrow_drop_down";
                    line-height: 3rem;
                }
            }

            > .dropdown-menu {
                top: auto;
                left: auto;
                bottom: auto;
                right: auto;
            }
        }
    }

    &.dropup {
        > .dropdown-menu:not([x-placement]) {
            bottom: auto;
            top: auto;
            left: auto;
            right: auto;
        }

        > .dropdown-toggle:after {
            content: "arrow_drop_up";
            line-height: 3rem;
        }
    }

    &.dropright {
        > .dropdown-menu:not([x-placement]) {
            left: 100%;
            right: auto;
            top: 0;
            bottom: auto;
        }

        > .dropdown-toggle:after {
            content: "arrow_right";
            line-height: 3rem;
        }
    }

    &.dropleft:not([x-placement]) {
        > .dropdown-menu {
            left: auto;
            right: 100%;
            top: 0;
            bottom: auto;
        }

        > .dropdown-toggle:before {
            line-height: 3rem;
        }
    }
}
